//
//  DENForumViewController.m
//  Icar
//
//  Created by apple on 15/10/16.
//  Copyright © 2015年 小龙侠. All rights reserved.
//

#import "DENForumViewController.h"
#import "LYYHotColumnModel.h"
#import "DENForumModel.h"
#import "LYYForumParkView.h"

@interface DENForumViewController ()

@property (nonatomic,retain)NSString *url;

@property (nonatomic,retain)UIView *titleView;

@property (nonatomic,retain)LYYForumParkView *collectionView;

@end

@implementation DENForumViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view.
    self.automaticallyAdjustsScrollViewInsets = NO;
    [self.navigationController.navigationBar setBarTintColor:BLUECOLOR];
    UILabel *titleLabel = [[UILabel alloc]initWithFrame:CGRectMake(WIDTH(170),0, WIDTH(60), HEIGHT(40))];
    [titleLabel setText:@"论坛"];
    [titleLabel setTextColor:[UIColor whiteColor]];
    [titleLabel setFont:[UIFont systemFontOfSize:24.]];
//    [_titleView addSubview:titleLabel];
    [self.navigationController.navigationBar addSubview:titleLabel];
    [self creatForumPark];
    
}

#pragma mark - 论坛广场
- (void)creatForumPark{
    
    self.collectionView = [[LYYForumParkView alloc]initWithFrame:CGRectMake(0, 64, WIDTH(375), HEIGHT(552))];
    [self.view addSubview:self.collectionView];
    [self.collectionView.collectionView setFrame:self.collectionView.bounds];
    self.collectionView.rootVC = self;
    [self.collectionView.collectionView reloadData];
}

- (void)viewWillAppear:(BOOL)animated{
    [self.collectionView.collectionView setBackgroundColor:[LYYNightModeHandle shareNightModeHandle].backColor];
    [self.collectionView.collectionView reloadData];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
